/*
 *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions are met:
 *
 *  Redistributions of source code must retain the above copyright notice,
 *  this list of conditions and the following disclaimer.
 *  Redistributions in binary form must reproduce the above copyright
 *  notice, this list of conditions and the following disclaimer in the
 *  documentation and/or other materials provided with the distribution.
 *  Neither the name of the dreamlu.net developer nor the names of its
 *  contributors may be used to endorse or promote products derived from
 *  this software without specific prior written permission.
 *  Author: Chill 庄骞 (smallchill@163.com)
 */
package org.springblade.modules.digitalization.service;

import cn.hutool.core.lang.Pair;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.springblade.core.mp.base.BaseService;
import org.springblade.core.tool.api.R;
import org.springblade.modules.digitalization.entity.A01Entity;
import org.springblade.modules.digitalization.entity.UmsUserInfoEntity;
import org.springblade.modules.digitalization.excel.A01ArchiveEntity;
import org.springblade.modules.digitalization.manager.DataExchangeCallback;
import org.springblade.modules.digitalization.vo.DataExchangeVO;
import org.springblade.modules.digitalization.vo.UmsUserInfoVO;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.io.IOException;
import java.util.List;

/**
 * 人员基础模型-JAVA 服务类
 *
 * @author RS
 * @since 2022-10-18
 */
public interface IUmsUserInfoService extends BaseService<UmsUserInfoEntity> {

	/**
	 * 自定义分页
	 *
	 * @param page
	 * @param umsUserInfo
	 * @return
	 */
	IPage<UmsUserInfoVO> selectUmsUserInfoPage(IPage<UmsUserInfoVO> page, UmsUserInfoVO umsUserInfo);

	/**
	 * 档案进行异步接收
	 *
	 * @param excel
	 * @param b0111
	 */
	void doReceiveAsync(MultipartFile excel, String b0111);

	List<A01ArchiveEntity> doImport(MultipartFile excel, String b0111);


	Boolean saveOneDa(UmsUserInfoEntity a01Entity);


	void doExchangeTask(DataExchangeVO dataExchangeVO, boolean enableHd, DataExchangeCallback callback);

	ResponseEntity<Resource> downData(HttpServletRequest request, String type, Long id) throws IOException;

	/**
	 * 档案审核
	 *
	 * @param a01
	 * @return
	 */
	String aduit(A01Entity a01);

	String scanRefuse(A01Entity a01);

	String mlRefuse(A01Entity a01);

	String checkMount(A01Entity a01);

	Pair<Boolean, String> isFileUploaded(String hash);

	R<String> doImportZip(MultipartFile file, String a0201b, boolean cover);

	R<String> doImportDir(String filePath, String a0201b, boolean cover);


}
